package cn.qf;

public class Company {

    public static void main(String[] args) {
        Department manager = new Department("Manager");
        System.out.println(manager);

        Department development = new Department("Development");
        System.out.println(development);

        System.out.println();

        // 管理部门决定修改公司名称为 NewBaidu
        manager.company = "NewBaidu";

        System.out.println(manager);
        System.out.println(development);

        System.out.println();

        // 开发部门决定把部门名称改为 “R&D”
        development.name = "R&D";

        System.out.println(manager);
        System.out.println(development);
    }

}
